{template 'common/header'}
<ul class="nav nav-tabs">
	<li {if $op == 'list'}class="active"{/if}><a href="{php echo $this->createWebUrl('slide',array('op' => 'list'))}">管理</a></li>
	<li {if $op == 'add'}class="active"{/if}><a href="{php echo $this->createWebUrl('slide',array('op' => 'add'))}">添加</a></li>
	
</ul>
<div class="main">
	<div class="panel panel-info">
		<div class="panel-heading">筛选</div>
		<div class="panel-body">
			<form action="" method="post" class="form-horizontal" role="form">
				<div class="form-group">
					<label class="col-xs-12 col-sm-2 col-md-2 control-label">关键字</label>
					<div class="col-sm-8 col-md-8 col-lg-8 col-xs-12">
						<input class="form-control" name="keyword" id="" type="text" value="{$_GPC['keyword']}">
					</div>
				</div>
				<div class="form-group">
					<div class="pull-right col-xs-12 col-sm-2 col-md-2 col-lg-2">
						<button class="btn btn-default"><i class="fa fa-search"></i> 搜索</button>
					</div>
				</div>
			</form>
		</div>
	</div>
	<div style="padding:15px;">
	<form action="" method="post">
		<table class="table table-hover table-striped">
			<thead class="navbar-inner">
				<tr>
					<th style="width:5%">排序</th>
					<th style="width:30%">标题</th>
					<th style="width:60%">操作</th>
				</tr>
			</thead>
			<tbody>
				{loop $list $item}
				<tr>
					<td><input type="text" class="form-control" name="displayorder[{$item['id']}]" value="{$item['displayorder']}" /></td>
					<td>
						{$item['title']}
					</td>
					<td>
					 	<a href="{php echo $this->createWebUrl('slide',array('op' => 'add','id' => $item['id']))}" title="编辑" class="btn btn-default btn-sm" ><i class="fa fa-edit" data-toggle="tooltip" data-placement="top"></i>编辑</a> 
                        
                        <a onclick="return confirm('此操作不可恢复，确认吗？'); return false;" href="{php echo $this->createWebUrl('slide',array('op' => 'delete','id' => $item['id']))}" title="" data-toggle="tooltip" data-placement="top" class="btn btn-default btn-sm" data-original-title="删除"><i class="fa fa-times"></i>删除</a>
					</td>
				</tr>
				{/loop}
				<tr>
					<td></td>
					<td colspan="2">
						<input name="submit" type="submit" class="btn btn-primary" value="提交">
						<input type="hidden" name="token" value="{$_W['token']}" />
					</td>
				</tr>
			</tbody>
		</table>
		</form>
		{$pager}
	</div>
</div>
{template 'common/footer'}